home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / newsgrp / group00b.txt / 000094_icon-group-sender_Tue Oct 24 08:17:21 2000.msg < prev    next >
Internet Message Format  |  2001-01-03  |  1KB

  1. Return-Path: <icon-group-sender>
  2. Received: (from root@localhost)
  3.     by baskerville.CS.Arizona.EDU (8.11.1/8.11.1) id e9OFFtT14377
  4.     for icon-group-addresses; Tue, 24 Oct 2000 08:15:55 -0700 (MST)
  5. Message-Id: <200010241515.e9OFFtT14377@baskerville.CS.Arizona.EDU>
  6. From: Nevin Liber <nevin@spies.com>
  7. Subject: Re: Icon beginner
  8. To: icon-group@cs.arizona.edu
  9. Date: Mon, 23 Oct 2000 18:30:48 -0700 (PDT)
  10. Errors-To: icon-group-errors@cs.arizona.edu
  11. Status: RO
  12. Content-Length: 516
  13.  
  14. Chris.D.Tenaglia@jci.com proudly exclaims:
  15.  
  16. > I like simple things like...
  17.  
  18. > procedure despace(str)
  19. >   new := ""
  20. >   every byte := !string do if byte ~== " " then new ||:= byte
  21. >   return new
  22. >   end
  23.  
  24. Another way I thought of doing it is like:
  25.  
  26.     procedure despace(s)
  27.  
  28.         s := string(s) | runerr(103, s)
  29.         while s[upto(' ', s)] := ""
  30.         return s
  31.  
  32.     end
  33.  
  34. but this method would require a bit more explanation
  35. (which I am leaving up to the reader for now).
  36. -- 
  37.  Nevin ":-)" Liber    <mailto:nevin@spies.com>    (773) 961-2479
  38.